package com.yulongtian.weekCompetition.month202301.week01;

import java.util.ArrayList;
import java.util.List;

/**
 * 第 326 场周赛
 * 可
 *
 * @author yulongTian
 * @create 2023-01-01 11:45
 */
public class Test01 {
    public static void main(String[] args) {

    }


    public static int countDigits(int num) {

        List<Integer> weis = new ArrayList<>();
        int tempNum = num;
        while (tempNum > 0) {
            weis.add(tempNum % 10);
            tempNum /= 10;
        }
        int ans = 0;
        for (Integer wei : weis) {
            if (num % wei == 0) {
                ans++;
            }
        }

        return ans;
    }
}
